package co.yixiang.modules.system.domain;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;
import lombok.experimental.Accessors;
import lombok.Builder;
import lombok.NoArgsConstructor;
import lombok.AllArgsConstructor;
import cn.hutool.core.bean.BeanUtil;
import cn.hutool.core.bean.copier.CopyOptions;
import javax.validation.constraints.*;
import java.time.LocalDateTime;
import java.io.Serializable;

/**
* @author db
* @date 2020-11-19
*/
@Data
@Accessors(chain = true)
@Builder
@NoArgsConstructor
@AllArgsConstructor
@TableName("business_cooperation")
public class BusinessCooperation implements Serializable {

    /** 主键 */
    @TableId
    private Integer id;


    /** 姓名 */
    private String name;


    /** 手机 */
    private String phone;


    /** 邮箱 */
    private String email;


    /** 行业 */
    private String business;


    /** 意见 */
    private String advise;


    /** 创建时间 */
    private LocalDateTime createTimes;


    /** 修改时间 */
    private LocalDateTime updateTimes;


    public void copy(BusinessCooperation source){
        BeanUtil.copyProperties(source,this, CopyOptions.create().setIgnoreNullValue(true));
    }
}
